'use client'
import React, {useRef} from 'react';

function UseRefLol() {
    const input = useRef<HTMLInputElement>(null)

    function show() {
        alert(input?.current?.value as string)
    }

    // setNum2(1)
    return (
        <div>
            <input type="text" ref={input}/>
            <button onClick={show}>弹出内容</button>
        </div>
    )
}

export default UseRefLol;